Formatting with Tables
Tables are a great way (heck, about the only way) to lay out a page
in an attractive design.
Classic Tables
Auto Sales | East | West |
1994 | $104,057 | $ 56,783 |
1995 | 79,943 | 48,322 |
1996 (est.) | 63,241 | 35,252 |
When you think of tables, you probably imagine something tabular
of the Excel kind, like the one at right.
Fer shure, that's a table and HTML can do that for you. (Of course it can,
you're looking at it, aren't you? No, it's not a bitmap.) Notice that you
can align text in the cells in different ways, use different colors for cells
(in MSIE but not in Netscape), insert links into the table items,
plus do all the tricks with fonts that you can outside of tables.
Tabular Trickery
Here's a not-quite-so-obvious use of tables. Let's say you want to show a series
of bullet items with text to the left of the items. You want to use a
graphic for the bullet. You want to indent the margins a lot.
And you want to center the whole mess. There are a few ways to do
this, but the table is the most flexible:
Tips for Writing Poetry
|
 |
It's always good to rhyme, but be creative. Try rhyming alternate
verses, or rhyme words in the middle of a syllable.
|
 |
Use unconventional words. If I see another "croon at the moon in June"
I will probably puke my guts out.
|
 |
Avoid haiku. If haiku is poetry then ketchup is a vegetable.
Now, limericks, there's real poetry for you.
|
So as you can see, tables can be used for a lot more than displaying
the gross national product of Slovenia for the past five years.
The home page at the WinMag Web site
is a complex combination of two tables nested inside each other.
Another example of nested tables is in the discussion of
URL components in this tutorial.
Once you figure those out you'll know you are an HTML table expert.
Table Troubles
Tables have been around for a while, and the stuff you see in this file
works pretty well with Netscape Navigator 2.0 and Internet Explorer 2.0.
Not all browsers support tables, though. The most ugly example is the
browser built into America Online 2.5. AOL plans to offer its users the
option to use a real browser by mid-1996, so I wouldn't let that keep
you from using tables. They do too many cool things to ignore them.
[Go back to Contents page]
Copyright ⌐ 1996 CMP Publications Inc.